package com.think.admin.oauth.rbac;

import lombok.Getter;
import lombok.RequiredArgsConstructor;
import org.springframework.security.core.GrantedAuthority;
import org.springframework.security.core.SpringSecurityCoreVersion;

/**
 * <p>
 * RBAC权限存储
 * </p>
 *
 * @author: xwj
 * @data: 2019-05-14
 */
@Getter
@RequiredArgsConstructor
public class RbacGrantedAuthority implements GrantedAuthority {
    private static final long serialVersionUID = SpringSecurityCoreVersion.SERIAL_VERSION_UID;
    private final String permission;
    private final String methodType;

    @Override
    public String getAuthority() {
        return permission;
    }
}
